{% extends "admin/base.html" %}

{% block content %}
    {% if not id %}
        <form action="/admin/article_manager/notice/add/" method="post">
            {% csrf_token %}
            <div class="el-textarea">
            <textarea placeholder="请输入内容" type="textarea" rows="5" autocomplete="off"
                      validateevent="true" class="el-textarea__inner"
                      name="text"
                      style="min-height: 33px;">{{ text }}</textarea>
            </div>
            <button type="submit" name="_save" class="el-button el-button--primary">保存</button>
        </form>
    {% else %}
        <form action="/admin/article_manager/notice/{{ id }}/change/" method="post">
            {% csrf_token %}
            <div class="el-textarea">
            <textarea placeholder="请输入内容" type="textarea" rows="5" autocomplete="off"
                      validateevent="true" class="el-textarea__inner"
                      name="text"
                      style="min-height: 33px;">{{ text }}</textarea>
            </div>
            <button type="submit" name="_save" class="el-button el-button--primary">保存</button>
        </form>
    {% endif %}
{% endblock %}